#pragma once
#include <vector>

// forward declaration
class Stroke;
namespace Gdiplus
{
	class Graphics;
	class Pen;
	class RectF;
};

class DistinctivePoint
{
	// declarations
	struct StrokePlace { 
		const Stroke* strokePtr; 
		int strokeID, place;
		float vx, vy;
	};

	typedef std::vector<StrokePlace> StrokePlacesCollection;

	// data
	float mX, mY, mT, mPrecision;
	int mID;
	static int sNextID;

	StrokePlacesCollection mStrokePlaces;

public:
	DistinctivePoint();

	void SetPosition(float x, float y);
	void AddDirection(float dx, float dy, const Stroke*, int strokeEnd);
	void SetCurveParameter(float t);

	bool IsTPoint() const;
	bool IsCorner() const;

	void Draw(Gdiplus::Graphics&, Gdiplus::Pen&, const Gdiplus::RectF&) const;
};

// another object
struct Junction
{
	const Stroke* strokes[2];
	int strokeEnds[2];
};


